/* function TreeNode(x) {
    this.val = x;
    this.left = null;
    this.right = null;
} */
function TreeDepth(pRoot)
{
    // write code here
    if(pRoot === null) return 0
    return TreeDepth(pRoot.left) > TreeDepth(pRoot.right) ? TreeDepth(pRoot.left) + 1 : TreeDepth(pRoot.right) + 1
}
module.exports = {
    TreeDepth : TreeDepth
};